import 'package:flutter/material.dart';
import 'package:my_translate/pages/recording_translate_page.dart';

import 'icon_demo_page.dart';

class TextFieldPage extends StatelessWidget {
  const TextFieldPage({Key? key}) : super(key: key);

  @override
  Widget build(BuildContext context) {
    return Card(
      elevation: 4,
      margin: EdgeInsets.all(0.0),
      child: Container(
        height: 200.0,
        child: Column(
          mainAxisAlignment: MainAxisAlignment.spaceBetween,
          children: [
            TextDemo(),
            IconDemo(),


          ],
        ),
      ),
    );
  }
}

class TextDemo extends StatelessWidget {
  const TextDemo({Key? key}) : super(key: key);

  @override
  Widget build(BuildContext context) {
    return Expanded(
        child: Container(
      height: MediaQuery.of(context).size.height,
      padding: EdgeInsets.only(left: 18.0, right: 18.0, bottom: 20.0, top: 2.0),
      child: TextField(
        decoration:
            InputDecoration(border: InputBorder.none, hintText: '点按即可输入文本'),
        style: TextStyle(color: Colors.black, fontSize: 25.0),
        maxLines: 999,
        cursorColor: Colors.green,
        cursorHeight: 2.0,
      ),
    ));
  }
}
